package rxjava2.groccery;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

public class WriteFile {

    public static void main(String[] args) {
        try {
            FileOutputStream fos = new FileOutputStream("./file.txt");
            FileInputStream fis = new FileInputStream("rxjava2/groccery/test.txt");

            byte[] buf = new byte[10];
            int len;
            while ((len = fis.read(buf)) != 0){

            }

        } catch (FileNotFoundException e) {

        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
